﻿' LibWowArmory
' by Ronald M. Clifford (roncli@roncli.com)
'
' This source code is released under the GNU Library General Public License (LGPL) Version 2.1.

Namespace roncliProductions.LibWowArmory.Character.Statistics

    ''' <summary>
    ''' A class that encapsulates a single statistic
    ''' </summary>
    ''' <remarks></remarks>
    Public Class Statistic

        ''' <summary>
        ''' The identification number of the statistic
        ''' </summary>
        ''' <value></value>
        ''' <returns></returns>
        ''' <remarks></remarks>
        Public Property StatisticID As Integer

        ''' <summary>
        ''' For statistics that deal with the most type of item that was used/killed/etc., this is the item that was used/killed/etc. the most
        ''' </summary>
        ''' <value></value>
        ''' <returns></returns>
        ''' <remarks></remarks>
        Public Property Highest As String

        ''' <summary>
        ''' The statistic's name
        ''' </summary>
        ''' <value></value>
        ''' <returns></returns>
        ''' <remarks></remarks>
        Public Property Name As String

        ''' <summary>
        ''' The quantity of the statistic
        ''' </summary>
        ''' <value></value>
        ''' <returns></returns>
        ''' <remarks></remarks>
        Public Property Quantity As Long

        ''' <summary>
        ''' A constructor that creates new statistic information
        ''' </summary>
        ''' <param name="intID"></param>
        ''' <param name="strName"></param>
        ''' <param name="strQuantity"></param>
        ''' <remarks></remarks>
        Public Sub New(ByVal intID As Integer, ByVal strName As String, ByVal strQuantity As String)
            StatisticID = intID
            Name = strName
            If Not Long.TryParse(strQuantity, Quantity) Then
                Quantity = 0
            End If
        End Sub

        ''' <summary>
        ''' A constructor that creates new statistic information
        ''' </summary>
        ''' <param name="intID"></param>
        ''' <param name="strHighest"></param>
        ''' <param name="strName"></param>
        ''' <param name="strQuantity"></param>
        ''' <remarks></remarks>
        Public Sub New(ByVal intID As Integer, ByVal strHighest As String, ByVal strName As String, ByVal strQuantity As String)
            StatisticID = intID
            Highest = strHighest
            Name = strName
            If Not Long.TryParse(strQuantity, Quantity) Then
                Quantity = 0
            End If
        End Sub

    End Class

End Namespace